/* Global Styles */
.car-table {
    font-family: Arial, sans-serif;
    width: 100%;
}

/* Table Styles */
table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    border: 1px solid #ccc; /* added external border */
}

th,
td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #ccc;
    border-right: 1px solid #ccc; /* added internal border */
}

th {
    background-color: #007bff;
    color: white;
}

tr:nth-child(even) {
    background-color: #f2f2f2;
}

tr:last-child td {
    border-bottom: none;  /* removed the border-bottom from the last row */
}

th:last-child,
td:last-child {
    border-right: none;  /* removed the border-right from the last column */
}

/* Controls (Add Car & Search Form) */
.controls {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

/* Buttons Styles */
button {
    background-color: #007bff;
    border: none;
    border-radius: 4px;
    color: white;
    padding: 6px 12px;
    cursor: pointer;
}

/* Add Car Button */
.add-car-btn {
    margin-right: 10px;
    margin-bottom: 10px;
}

/* Search Container */
.search-container {
    display: flex;
    align-items: center;
}

/* Search Button */
.search-btn {
    border-radius: 4px 0 0 4px;
    white-space: nowrap; /* 确保按钮文字不换行 */
}

/* Search Input */
.search-input {
    border: 1px solid #ccc;
    border-radius: 0;
    padding: 6px 12px;
    outline: none;
}

/* Car Image */
.car-image {
    width: 50px;
    height: 50px;
    object-fit: cover;
    border-radius: 4px;
}

/* Table Actions (Edit & Delete) */
.actions a {
    margin-right: 8px;
    color: #007bff;
}

.actions a:hover {
    text-decoration: underline;
}

/* File Input (Upload Image) */
.file-input {
    display: none;
}

input[type="file"] + label {
    cursor: pointer;
    color: #fff;
    background-color: #007bff;
    border-radius: 4px;
    padding: 5px 10px;
}